SELECT t.${entityMapper.tableName}_CODE, t.NAME FROM ${entityMapper.tableName} t
where t.state_code ='1' and t.data_state_code = '1'
<${r"#"}if cardone.StringUtils.isBlank(notTerm) >
    <${r"#"}if cardone.StringUtils.isNotBlank(term)>
    and (INSTR(t.NAME, :term) > 0 OR INSTR(t.${entityMapper.tableName}_CODE, :term) > 0)
    </${r"#"}if>
</${r"#"}if>
AND ROWNUM <= 20
ORDER BY T.ORDER_BY_, T.${entityMapper.tableName}_CODE